home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.19970626-19970929 / 000312_news@newsmaster….columbia.edu _Mon Sep 8 09:54:22 1997.msg < prev    next >
Internet Message Format  |  2020-01-01  |  8KB

  1. Return-Path: <news@newsmaster.cc.columbia.edu>
  2. Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.35.30])
  3.     by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id JAA22339
  4.     for <kermit.misc@watsun.cc.columbia.edu>; Mon, 8 Sep 1997 09:54:22 -0400 (EDT)
  5. Received: (from news@localhost)
  6.     by newsmaster.cc.columbia.edu (8.8.5/8.8.5) id JAA00825
  7.     for kermit.misc@watsun; Mon, 8 Sep 1997 09:54:21 -0400 (EDT)
  8. Path: news.columbia.edu!watsun.cc.columbia.edu!jaltman
  9. From: jaltman@watsun.cc.columbia.edu (Jeffrey Altman)
  10. Newsgroups: comp.protocols.kermit.misc
  11. Subject: Re: MSDOS Kermit to Kermit/2 script conversion notes
  12. Date: 8 Sep 1997 13:54:19 GMT
  13. Organization: Columbia University
  14. Lines: 168
  15. Message-ID: <5v102b$cen$1@apakabar.cc.columbia.edu>
  16. References: <TCPSMTP.17.9.8.2.15.0.2375661496.4677362@kincyb.com>
  17. NNTP-Posting-Host: watsun.cc.columbia.edu
  18. Xref: news.columbia.edu comp.protocols.kermit.misc:7635
  19.  
  20. In article <TCPSMTP.17.9.8.2.15.0.2375661496.4677362@kincyb.com>,
  21.  <dallasii@kincyb.com> wrote:
  22. : [I'm cross-posting this to several forums where I think it will be
  23. : appropriate for discussion.
  24. : I apologize to anyone who finds it inappropriate (or long winded).]
  25.  
  26. It is considered polite to cross-post by listing all of the newsgroups
  27. in one copy of the post instead of sending separate posts to each
  28. group.  That way every group gets to see the responses.
  29.  
  30. : Some notes on converting command files from MS-DOS Kermit 3.14 to
  31. : Kermit/2 (Kermit-95 (C-Kermit for Windows-95) for OS/2)
  32. : (henceforth referred to as K2, K/2 or K2.EXE)
  33. : I welcome any comments:
  34. : 1) The OS/2 "EXTPROC" command seems to be the most underdocumented
  35. :    OS/2 command I've come across.  Few of the BIG, THICK OS/2 books
  36. :    (henceforth referred to as BTOB's) had much on it.  Almost nowhere
  37. :    was there a real working example of it.
  38. :    I expected it to be something similar to the UNIX 
  39. :    "#!/full/path/specification/to/the/interpreter" feature for the
  40. :    first line of a script.  Almost, but not quite.
  41. :    The documentation all said something to the effect of:
  42. :    EXTPROC <device>:\full\path\interpreter <parameters here>
  43.  
  44. That is the correct syntax for EXTPROC, but ...
  45.  
  46. :    I *expected* to use something like:
  47. :    EXTPROC <device>:\full\path\k2.exe = %1 %2 %3 %4 %5  %6 %7 %8 %9
  48.  
  49. This is not the syntax for Kermit-95.  K95 (and C-Kermit) requires that
  50. the command file be the first parameter on the command line.
  51.  
  52. :  on the first line of the procs to use them as OS/2 commands that
  53. : would pass the parameters to the script previously used for
  54. : MS-DOS Kermit into \&@[0] ... \&@[8].
  55. : What I found was needed was:
  56. :    EXTPROC <device>:\full\path\k2.exe <device>:\full\path\to\the\script.cmd
  57.  
  58. That is almost correct.
  59.  
  60. Try just 
  61.  
  62.     EXTPROC K2.EXE 
  63.  
  64. assuming that K2.EXE is in your PATH.  Then it should work fine.  OS/2
  65. will expand the current .CMD file and use that as the first parameter,
  66. and then the .CMD command line parameters will follow it.
  67.  
  68. You can then access the command line parameters using command line
  69. argument array \&@[].
  70.  
  71. : A further example:
  72. : file1 (ktest5.cmd):
  73. : ************************************************************
  74. : EXTPROC D:\K2\K2.EXE C:\USR\COMM\Ktest6.CMD
  75. : ;                                     A--Note
  76. : ; LAFN login script
  77. : ; DEL 30/01/97
  78. : echo \&@[0] \&@[1] \&@[2] \&@[3] \&@[4] \&@[5] \&@[6]
  79. : IF DEFINED \&@[3] ASSIGN \%1 \&@[3] 
  80. : IF DEFINED \&@[4] ASSIGN \%2 \&@[4]
  81. : IF DEFINED \&@[5] ASSIGN \%3 \&@[5]
  82. : echo \%1 \%2  \%3 \%4 \7 \7 \7 \7 \7 the input
  83. : echo Ktest5!\13\10
  84. : EXIT
  85. : *****************************************************************
  86.  
  87. This runs Ktest6.cmd instead of Ktest5.cmd because you have hard coded 
  88. the first parameter passed to K95 to be ktest6.cmd.
  89.  
  90. : file2 (ktest6.cmd):
  91. : ******************************************************************
  92. : EXTPROC D:\K2\K2.EXE C:\USR\COMM\Ktest6.CMD
  93. : ; LAFN login script
  94. : ; DEL 30/01/97
  95. : echo Suprise, you got Ktest6 instead!\13\10
  96. : EXIT
  97. : *******************************************************************
  98.  
  99. : Yes, I was suprised. 
  100. : EXTPROC seems to work as a comment most of the time, and
  101. : under certain circumstances as non-returning branch.
  102.  
  103. In K95 EXTPROC is exactly equivalent to COMMENT.  It is a alias.
  104.  
  105. : (one of the goals here is a command "lynx <password>" that will take 
  106. : me directly from the OS/2 command line to my LA FreeNet account
  107. : with Lynx active on my screen.)
  108.  
  109. You could do that with regular .CMD and .KSC files and bypass the
  110. EXTPROC procedures.
  111.  
  112. : 2) While functioning as a comment in K/2, and apparently in
  113. : most versions of C-Kermit, EXTPROC required some bogus
  114. : definition as a macro to minimize interuption when scripts
  115. : were run back with MS-DOS Kermit, I think I just 
  116. : "define EXTPROC echo" in my MSCUSTOM.INI file to allow things
  117. : to flow smoothly.
  118.  
  119. EXTPROC is not supported in DOS.  Therefore, I do not believe that
  120. anybody ever thought to add it there.
  121.  
  122. : 4) The GUI dialer works fine for targets where dialing in
  123. : usually goes quickly with lots of open ports.  With targets
  124. : like a University mainframe on a Sunday afternoone, where 
  125. : everyone is trying to get their homework assignments finished,
  126. : or my previous eMail provider, I found I needed scripts that
  127. : would keep trying till they got through.  Is there someway
  128. : to set up the dialer so it will accept the userid/password
  129. : as parameters, or ask you for them, without storing them, 
  130. : when invoked, then pass them to the dialup script.  
  131. : This may just be a point of my own ignorance about the Dialer & GUIs.
  132. : I know it can be built into the scripts, but it seems like this
  133. : should be just as much a part of the Dialer as the ability to
  134. : store non-unique non-security issue passwords permenantly in the 
  135. : Dialer database.
  136.  
  137. The dialer provides for automatic retries.  No scripting required.
  138. This is built into K95's DIAL command.  The number of retries,
  139. interval between retries, etc are located on the Location->General
  140. page.
  141.  
  142. If your host has multiple phone numbers you want to try use a Dialing
  143. directory and specify the dialing directory entry name in the phone
  144. number field instead of an actual phone number.  K95 will auto-dial
  145. through the entire list.
  146.  
  147. The dialer will not prompt for the password.  However, you can specify
  148. your own wrapper script that will prompt for the password and then
  149. TAKE LOGIN.KSC to login.  I will consider adding this feature.
  150.  
  151. : 5) I found I was frequently having to modify portions of the
  152. : scripts to have a set of commands like:
  153. : input <n> <some string>
  154. : reinput 1 <the same string>
  155. : It seems that when it's late at night, the target/host CPU has little
  156. : to occupy it, and the not so busy phone lines allow a 28,800 connection
  157. : maybe the prompts that the target are sending sneak through before interpreter
  158. : on my feeble '386 is ready to respond, so it needs to recheck 
  159. : the received input to find something that was missed.  When the host is
  160. : busy and responds sluggishly, the phone lines are clogged and don't
  161. : allow such fast connections the "input" command will catch the prompt
  162. : itself.  But this doesn't make any sense since everything must go through
  163. : my CPU (the one running K/2) anyway, so why should it miss anything to begin
  164. : with? Is this some sort of interupt/multi-threading issue, or am I just
  165. : working to late on this to think clearly?
  166.  
  167. You will have to show us the script you are using to login in for us
  168. to help you on this one.  Of course, the usual things apply when using
  169. high speed modems make sure that your flow control for the modem and
  170. the serial port are set to Hardware Flow Control so that you do not
  171. lose data and be sure to use a buffered UART such as a 16550.
  172.  
  173. Send support questions to kermit-support@columbia.edu.
  174.  
  175.     Jeffrey Altman * Sr.Software Designer * Kermit-95 for Win32 and OS/2
  176.                  The Kermit Project * Columbia University
  177.        612 West 115th St #716 * New York, NY * 10025 * (212) 854-1344
  178.     http://www.columbia.edu/kermit/k95.html * kermit-support@columbia.edu